home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group98b.txt / 000114_icon-group-sender _Mon Jun 29 08:41:21 1998.msg < prev    next >
Internet Message Format  |  2000-09-20  |  1KB

  1. Return-Path: <icon-group-sender>
  2. Received: from kingfisher.CS.Arizona.EDU (kingfisher.CS.Arizona.EDU [192.12.69.239])
  3.     by baskerville.CS.Arizona.EDU (8.8.8/8.8.7) with SMTP id IAA06676
  4.     for <icon-group-addresses@baskerville.CS.Arizona.EDU>; Mon, 29 Jun 1998 08:41:21 -0700 (MST)
  5. Received: by kingfisher.CS.Arizona.EDU (5.65v4.0/1.1.8.2/08Nov94-0446PM)
  6.     id AA01032; Mon, 29 Jun 1998 08:41:09 -0700
  7. Message-Id: <35970078.4332DA12@ix.netcom.com>
  8. Date: Sun, 28 Jun 1998 22:48:24 -0400
  9. From: Phillip Lee Thomas <teruthom@ix.netcom.com>
  10. Reply-To: thomaspl@acm.org
  11. X-Mailer: Mozilla 4.05 [en] (Win95; U)
  12. Mime-Version: 1.0
  13. To: icon-group@optima.CS.Arizona.EDU
  14. Subject: Retrieving lists from tables
  15. Content-Type: text/plain; charset=us-ascii
  16. Content-Transfer-Encoding: 7bit
  17. Errors-To: icon-group-errors@optima.CS.Arizona.EDU
  18. Status: RO
  19. Content-Length: 575
  20.  
  21. I'm working on a project where it would be most convenient to store
  22. information in a table where the index is a list and the value is a
  23. record; however, I find it not obvious how to retrieve the data as lists
  24. are retrieved by their ID number, not their value. Any suggestions?
  25.  
  26. record ref(part1,part2)
  27. # Initially...
  28.         t := table()
  29.         L := ["house","horse"]
  30.         t[L] := ref(1,2)
  31. # Later...
  32.        L2 := ["house","horse"]
  33. Now I want to find out if a list with the content of L2 is in table t,
  34. and if so to augment the value of its part1.
  35.  
  36. -- Phillip Thomas
  37.  
  38.  
  39.  
  40.